package com.xinxing.city.recovery;

import android.app.Application;
import android.content.Context;


import androidx.multidex.MultiDex;

import com.google.inject.Module;
import com.xinxing.city.recovery.modules.RecoveryModules;
import com.xinxing.city.recovery.utils.Logger;

import roboguice.RoboGuice;

public class RecoveryApplication extends Application {

    private static RecoveryApplication instance;
    public static RecoveryApplication getInstance() {
        return instance;
    }
    private String token="";
    private String orderCode ="";
    private String yhCode = "";
    @Override
    public void onCreate() {
        super.onCreate();
        instance = this;
        Logger.init(this);
        RoboGuice.setUseAnnotationDatabases(false);

        DI.setInjector(RoboGuice.getOrCreateBaseApplicationInjector(this, RoboGuice.DEFAULT_STAGE, getModules()));
    }
    protected void attachBaseContext(Context base) {
        super.attachBaseContext(base);
        MultiDex.install(this) ;
    }
    private Module[] getModules()
    {
        Module[] modules = {
                new RecoveryModules()
        };

        return modules;
    }

    public String getToken() {
        return token;
    }

    public void setToken(String token) {
        this.token = token;
    }

    public String getOrderCode() {
        return orderCode;
    }

    public void setOrderCode(String orderCode) {
        this.orderCode = orderCode;
    }

    public String getYhCode() {
        return yhCode;
    }

    public void setYhCode(String yhCode) {
        this.yhCode = yhCode;
    }

}
